The imf
form defines graphical images in a
platform-independent way.
An image family is a named collection of images of varying
sizes and depths.
Form: imf
name [ properties ] [ images ]
This form declares an image family to exist, with the name name
and properties, and consisting of the specified images.
Each image has the form
((w h [tile]) [properties] (type data...) ...)
,
where w and h are its width and height, respectively,
the type may be one of color
, mono
, or mask
,
and the data consists of strings of hexadecimal digits.
The data strings may include slashes, which have no effect on interpretation,
but are useful to indicate each row of an image.
Color images may also have additional properties, which come between the
type and the data.
The family's name may consist only of alphabetic characters, decimal digits, and hyphens or underscores. Upper- and lower-case characters are equivalent, as are hyphens and underscores. The canonical form of the name is lowercase with hyphens.
Multiple forms with the same name may occur, and each adds to the family, overwriting individual image parts that are of the same size and depth.
Symbol: tile
If this symbol appears following the dimensions of an image, it indicates that the image is a pattern tile rather than a single image.
ImageProperty: actual
w h
This property is the actual size of the image data.
ImageProperty: embed
name
This property specifies that another image, similar to the image family named by name, is already embedded within the image, and so Xconq need not superimpose such an image itself. This may occur when an image has a "builtin" side emblem, or is readily identifiable as belonging to a particular side, and it would be redundant for Xconq to add an emblem when displaying a unit.
ImageProperty: embed-at
x y
This property specifies that the area of the image at x,y is suitable for the display of an emblem.
ImageProperty: embed-size
w h
This property specifies the dimensions of the area available for an emblem.
ImageProperty: mono
data ...
This property indicates that the data represents a monochrome image.
ImageProperty: mask
data ...
This property indicates that the data represents a mask.
ImageProperty: color
[ properties ] data ...
This property indicates that the data represents a color image.
ColorImageProperty: pixel-size
n
This property is the number of bits used to encode each pixel.
ColorImageProperty: palette
[ name | (index r g b) ... ]
This property is the color palette that should be used with the image.
Form: palette
name (index r g b) ...
This form defines a palette with the given name.
Note that for the purposes of stability and change tracking, tools that generate image families use a more restricted format. This format requires a separate imf form for each size of image, the size is on the same line as the imf name, and each image/mask is on a separate line, indented by 2. (See the existing library imf files for further detail.)